import request from '@/utils/request'
import { baseUrl } from '@/config/env';

export const getMenberList = (data={}) => {
  console.log(data, '0000')
  let string = '';
  if (data.name) {
    string += `?name=${data.name}`
  }
  if (data.beginTime) {
    string ? string += `&beginTime=${data.beginTime}` : string += `?beginTime=${data.beginTime}`
  }

  if (data.endTime) {
    string += `&endTime=${data.endTime}`
  }
  console.log(string, '1111')
  return request({
    url: `${baseUrl}/rest/member/list${string}`,
    method: 'get'
  })
}

export const editMember = (data) => {
  console.log(data, 'aaaaa')
  return request({
    url: baseUrl+'/rest/member/info/edit',
    method: 'post',
    data
  })
}


